From: Vijaya Kumar K Date: Fri, 20 Mar 2015 16:38:40 +0000 (+0100) Subject: use linked list accessors for page_list helper functions X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~3545^2 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=4366f3e99f64fbbe44e3cdac9ae7dbdd72296bc9;p=xen.git use linked list accessors for page_list helper functions Use newly introduced linked list helper functions in page_list* functions Signed-off-by: Vijaya Kumar K --- diff --git a/xen/include/xen/mm.h b/xen/include/xen/mm.h index fd60c9c9f6..a769084d9a 100644 --- a/xen/include/xen/mm.h +++ b/xen/include/xen/mm.h @@ -338,14 +338,12 @@ page_list_splice(struct page_list_head *list, struct page_list_head *head) # define INIT_PAGE_LIST_HEAD INIT_LIST_HEAD # define INIT_PAGE_LIST_ENTRY INIT_LIST_HEAD # define page_list_empty list_empty -# define page_list_first(hd) list_entry((hd)->next, \ - struct page_info, list) -# define page_list_last(hd) list_entry((hd)->prev, \ - struct page_info, list) -# define page_list_next(pg, hd) list_entry((pg)->list.next, \ - struct page_info, list) -# define page_list_prev(pg, hd) list_entry((pg)->list.prev, \ - struct page_info, list) +# define page_list_first(hd) \ + list_first_entry(hd, struct page_info, list) +# define page_list_last(hd) \ + list_last_entry(hd, struct page_info, list) +# define page_list_next(pg, hd) list_next_entry(pg, list) +# define page_list_prev(pg, hd) list_prev_entry(pg, list) # define page_list_add(pg, hd) list_add(&(pg)->list, hd) # define page_list_add_tail(pg, hd) list_add_tail(&(pg)->list, hd) # define page_list_del(pg, hd) list_del(&(pg)->list)